
const  routesConfig = [
  {
    name: ' 登录',
    path: '/login',
    component: './Login',
    // https://umijs.org/docs/max/layout-menu#%E9%85%8D%E7%BD%AE
    layout: false,
  },
  {
    path: '/',
    redirect: '/home'
  },
  {
    name: '首页',
    path: '/home',
    icon: 'PieChartOutlined',
    component: './Home',
  },
  {
    name: '系统管理',
    path: '/sys',
    icon: 'KeyOutlined',
    routes: [
      {
        name: '菜单管理',
        path: 'menus',
        icon: 'FolderOpenOutlined',
        component: './Menus',
      },
      {
        name: '字典管理',
        path: 'dict',
        icon: 'GiftOutlined',
        component: './Dict',
      }
    ]
  },
  {
    name: '用户管理',
    path: '/user',
    icon: 'CommentOutlined',
    routes: [
      {
        name: '用户管理',
        path: 'manage',
        icon: 'UserOutlined',
        routes: [
          {
            name: '用户管理',
            path: '',
            component: './User',
          },
          {
            name: '用户角色',
            path: 'role/:userId',
            component: './User/Role',
            // 隐藏自己和子菜单
            hideInMenu: true
          },
        ]
      },
      {
        name: '角色管理',
        path: 'role',
        component: './Role',
        icon: 'KeyOutlined',
      },
    ]
  },
  {
    name: 'Nginx管理',
    path: '/nginx',
    icon: 'NodeIndexOutlined',
    routes: [
      {
        name: '域名管理',
        path: 'domain',
        icon: 'VerifiedOutlined',
        component: './Nginx/Ssl',
      },
      {
        name: '云厂商Access管理',
        path: 'cloudAccess',
        icon: 'VerifiedOutlined',
        routes: [
          {
            name: '云厂商Access管理',
            path: '',
            icon: 'VerifiedOutlined',
            component: './Nginx/CloudAccess',
          },
          {
            name: '域名解析',
            path: 'dp/:accessId',
            component: './Nginx/CloudAccess/DomainParsing',
            // 隐藏自己和子菜单
            hideInMenu: true
          },
          {
            name: '解析设置',
            path: 'dpr/:domain',
            component: './Nginx/CloudAccess/DomainParsingRecord',
            // 隐藏自己和子菜单
            hideInMenu: true
          }
        ]
      },
    ]
  },
  {
    name: '服务器管理',
    path: '/server',
    icon: 'CloudServerOutlined',
    routes: [
      {
        name: 'SSH管理',
        path: 'ssh',
        icon: 'LinuxOutlined',
        component: './Server',
      },
      {
        name: '被使用端口',
        path: 'usePort',
        icon: 'PinterestOutlined',
        component: './UsePort',
      }
    ]
  },
  {
    name: '备份管理',
    path: '/backup',
    icon: 'FileDoneOutlined',
    routes: [
      {
        name: '备份文件信息',
        path: 'files/:dbId',
        component: './Backup/Files',
        // 隐藏自己和子菜单
        hideInMenu: true
      },
      {
        name: '数据库备份',
        path: 'db',
        icon: 'BgColorsOutlined',
        component: './Backup/Db',
      }
    ]
  },
  {
    name: '消息管理',
    path: '/msg',
    icon: 'DingtalkOutlined',
    routes: [
      {
        name: 'WebHook',
        path: 'webhook',
        icon: 'DingtalkOutlined',
        component: './Message/WebHook',
      }
    ]
  },
  {
    name: '密钥管理',
    path: '/pwd',
    icon: 'KeyOutlined',
    routes: [
      {
        name: '业务密码',
        path: 'business',
        icon: 'EyeInvisibleOutlined',
        component: './Pwd',
      }
    ]
  },
  {
    name: '定时器管理',
    path: '/quartz',
    icon: 'HistoryOutlined',
    routes: [
      {
        name: '元数据',
        path: 'meta',
        icon: 'TableOutlined',
        component: './Quartz/Meta',
      },
      {
        name: '任务管理',
        path: 'job',
        icon: 'FireOutlined',
        component: './Quartz/Job',
      }
    ]
  },
  {
    name: '日志管理',
    path: '/log',
    icon: 'HighlightOutlined',
    routes: [
      {
        name: '登录日志',
        path: 'login',
        icon: 'LoginOutlined',
        component: './Log/UserLogin',
      }
    ]
  },

  // {
  //   name: '权限演示',
  //   path: '/access',
  //   component: './Access',
  // },
  // {
  //   name: ' CRUD 示例',
  //   path: '/table',
  //   component: './Table',
  // },
];

export default routesConfig;
